  catch(int index)
    {
        if (index < 0 || index>9)
            cout << index << " out of bound" << endl;
        else if(index==0) cout << "divide by 0";
    }